1 Parkinsons Univariate Options Analysis

1.0.1 Loading the libraries

library("FRESA.CAD")
library(readxl)
library("whitening")
library("fpc")
library("robust")
op <- par(no.readonly = TRUE)
pander::panderOptions('digits', 3)
pander::panderOptions('table.split.table', 400)
pander::panderOptions('keep.trailing.zeros',TRUE)
TrainFraction <- 0.50;

dataLoad = FALSE

1.1 The Data


pd_speech_features <- as.data.frame(read_excel("~/GitHub/FCA/Data/pd_speech_features.xlsx",sheet = "pd_speech_features", range = "A2:ACB758"))

1.1.1 The Average of the Three Repetitions

Each subject had three repeated observations. Here I’ll use the average of the three experiments per subject.

rep1Parkison <- subset(pd_speech_features,RID==1)
rownames(rep1Parkison) <- rep1Parkison$id
rep1Parkison$id <- NULL
rep1Parkison$RID <- NULL
rep1Parkison[,1:ncol(rep1Parkison)] <- sapply(rep1Parkison,as.numeric)

rep2Parkison <- subset(pd_speech_features,RID==2)
rownames(rep2Parkison) <- rep2Parkison$id
rep2Parkison$id <- NULL
rep2Parkison$RID <- NULL
rep2Parkison[,1:ncol(rep2Parkison)] <- sapply(rep2Parkison,as.numeric)

rep3Parkison <- subset(pd_speech_features,RID==3)
rownames(rep3Parkison) <- rep3Parkison$id
rep3Parkison$id <- NULL
rep3Parkison$RID <- NULL
rep3Parkison[,1:ncol(rep3Parkison)] <- sapply(rep3Parkison,as.numeric)

whof <- !(colnames(rep1Parkison) %in% c("gender","class"));
avgParkison <- rep1Parkison;
avgParkison[,whof] <- (rep1Parkison[,whof] + rep2Parkison[,whof] + rep3Parkison[,whof])/3

pander::pander(table(avgParkison$class))
0 1
64 188


set.seed(1)
trainCases <- sample(nrow(avgParkison),nrow(avgParkison)*TrainFraction)

avgParkison_train <- avgParkison[trainCases,]
avgParkison_test <- avgParkison[-trainCases,]

pander::pander(table(avgParkison_train$class))
0 1
31 95
pander::pander(table(avgParkison_test$class))
0 1
33 93

1.1.1.1 Analysis parameters

dataframe <- avgParkison_train
dataframeTest <- avgParkison_test
outcome <- "class"

1.1.2 All the run options

sig_pvalue <- 0.05
thr <- c(0.05,0.2,0.4,0.6,0.8,0.95);
method  <- c("fast","pearson","spearman");
type <- c("LM","RLM")
DeOutcome <- c("T_Blind","T_Driven")
corRank <- c(FALSE,TRUE)

#method  <- c("fast","pearson","spearman");
#type <- c("LM","RLM")

1.2 Decorrelation Analysis


if (dataLoad)
{
  load("~/GitHub/LatentBiomarkers/RMD/Parkinsons_ALL_Options.RData")
} else
{
  
  idx = 0;
  thenames <- list();
  totBaM <- NULL
  totDeM <- NULL
  toUnmatM <- NULL
  unalteredM <- NULL
  Decorrleated_FractionM<- NULL
  Base_FractionM<- NULL
  Unaltered_FractionM <- NULL
  sparcityM <- NULL
  Average_Latent_SizeM <- NULL
  SigDeM <- NULL
  La_SignificantM <- NULL
  pbKNNaucM <- NULL
  pbKNNaccM <- NULL
  
  for (DeOut in DeOutcome)
  {
    for (meth in method)
    {
      for (typ in type)
      {
        for (corran in corRank)
        {
          par(op)
          par(mfrow=c(3,2),cex=0.5)
          idx <- idx + 1;
          thenames[[idx]] <- paste(DeOut,meth,typ,corran,sep="_")
          totBa <- numeric()
          totDe <- numeric()
          toUnmat <- numeric()
          unaltered <- numeric()
          Decorrleated_Fraction<- numeric()
          Base_Fraction<- numeric()
          Unaltered_Fraction <- numeric()
          sparcity <- numeric()
          Average_Latent_Size  <- numeric()
          SigDe <- numeric()
          La_Significant <- numeric()
          pbKNNauc <- numeric()
          pbKNNacc <- numeric()
          for (thrs in thr)
          {
            print(thenames[[idx]])
            plotname <- paste(thenames[[idx]],thrs,sep="_")
            
  
            if (DeOut != "T_Driven")
            {
              DEdataframeTrain <- IDeA(dataframe,
                                                     thr=thrs,
                                                     method=meth,
                                                     type=typ,
                                                     corRank=corran,
                                                     relaxed=TRUE,
                                                     verbose = FALSE)
            } else
            {
              DEdataframeTrain <- IDeA(dataframe,
                                                     Outcome=outcome,
                                                     thr=thrs,
                                                     method=meth,
                                                     type=typ,
                                                     corRank=corran,
                                                     relaxed=TRUE,
                                                     verbose = FALSE)
            }
            demat <- attr(DEdataframeTrain,"UPSTM")
            DEdataframe <- predictDecorrelate(DEdataframeTrain,dataframeTest)
            
            totFe <- ncol(DEdataframe)-1
            totBa <- c(totBa,length(attr(DEdataframeTrain,"unaltered")))
            totDe <- c(totDe, sum(str_detect(colnames(DEdataframe),"La_")))
            toUn <- sum(apply(demat!=0,2,sum)==1)
            toUnmat <- c(toUnmat,toUn )
            una <-  totFe - ncol(demat) + toUn
            unaltered <- c(unaltered,una)
            Decorrleated_Fraction <- c(Decorrleated_Fraction,sum(str_detect(colnames(DEdataframe),"La_"))/totFe)
            Base_Fraction <- c(Base_Fraction,length(attr(DEdataframeTrain,"unaltered"))/totFe)
#            print(totBa)
            
            Unaltered_Fraction <- c(Unaltered_Fraction,una/totFe)
            sparcity <- c(sparcity,(totFe-ncol(demat)+sum(abs(demat)!=0))/totFe/totFe)
            
            varlistDe <-  colnames(demat)[apply(demat!=0,2,sum)>1];
            varlistDe <- as.data.frame(cbind(name=varlistDe,desc=varlistDe))
            
            
            varlist_DeAll <- colnames(DEdataframe)
            varlist_DeAll <- varlist_DeAll[!(varlist_DeAll %in% c(outcome))]
            varlist_DeAll <- as.data.frame(cbind(name=varlist_DeAll,desc=varlist_DeAll))
            
  
            
            pDe <- univariate_Wilcoxon(DEdataframeTrain,outcome,pvalue=sig_pvalue);
            topDecorNames <- names(pDe);
  
            dc <- getLatentCoefficients(DEdataframeTrain)
            deNames_in_dc <- topDecorNames[topDecorNames %in% names(dc)]
            selectedlist <- dc[deNames_in_dc]
            theDeFormulas <- selectedlist
            
            
            Average_Latent_Size <- c(Average_Latent_Size,length(unlist(theDeFormulas))/length(theDeFormulas))
            
            topSigDe <- topDecorNames
            
            pDeDe <- pDe[names(pDe) %in% varlistDe[,1]]

            La_Significant <- c(La_Significant,length(topSigDe))
            SigDe <- c(SigDe,length(pDeDe))
  
            
            mlKNN <- KNN_method(formula(paste(outcome,"~.")),DEdataframeTrain[,c(outcome,topSigDe)])
            psb <- predictionStats_binary(cbind(dataframeTest[,outcome],
                                                  predict(mlKNN,
                                                  DEdataframe[,c(outcome,topSigDe)])),plotname,cex=0.6)
            pbKNNauc <- c(pbKNNauc,psb$aucs[1])
            pbKNNacc <- c(pbKNNacc,psb$accc[1])
          }
          totBaM <- rbind(totBaM,totBa)
          totDeM <- rbind(totDeM,totDe)
          toUnmatM <- rbind(toUnmatM,toUnmat)
          unalteredM <- rbind(unalteredM,unaltered)
          Decorrleated_FractionM <- rbind(Decorrleated_FractionM,Decorrleated_Fraction)
          Base_FractionM <- rbind(Base_FractionM,Base_Fraction)
          Unaltered_FractionM <- rbind(Unaltered_FractionM,Unaltered_Fraction)
          sparcityM <- rbind(sparcityM,sparcity)
          Average_Latent_SizeM <- rbind(Average_Latent_SizeM,Average_Latent_Size)
          SigDeM <- rbind(SigDeM,SigDe)
          La_SignificantM <- rbind(La_SignificantM,La_Significant)
          pbKNNaucM <- rbind(pbKNNaucM,pbKNNauc)
          pbKNNaccM <- rbind(pbKNNaccM,pbKNNacc)
  
        }
      }
    }
  }
}

[1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.05 [1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.2 [1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.4 [1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.6 [1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.8 [1] “T_Blind_fast_LM_FALSE” T_Blind_fast_LM_FALSE_0.95 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.05 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.2 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.4 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.6 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.8 [1] “T_Blind_fast_LM_TRUE” T_Blind_fast_LM_TRUE_0.95 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.05 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.2 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.4 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.6 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.8 [1] “T_Blind_fast_RLM_FALSE” T_Blind_fast_RLM_FALSE_0.95 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.05 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.2 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.4 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.6 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.8 [1] “T_Blind_fast_RLM_TRUE” T_Blind_fast_RLM_TRUE_0.95 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.05 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.2 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.4 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.6 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.8 [1] “T_Blind_pearson_LM_FALSE” T_Blind_pearson_LM_FALSE_0.95 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.05 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.2 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.4 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.6 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.8 [1] “T_Blind_pearson_LM_TRUE” T_Blind_pearson_LM_TRUE_0.95 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.05 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.2 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.4 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.6 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.8 [1] “T_Blind_pearson_RLM_FALSE” T_Blind_pearson_RLM_FALSE_0.95 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.05 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.2 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.4 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.6 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.8 [1] “T_Blind_pearson_RLM_TRUE” T_Blind_pearson_RLM_TRUE_0.95 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.05 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.2 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.4 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.6 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.8 [1] “T_Blind_spearman_LM_FALSE” T_Blind_spearman_LM_FALSE_0.95 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.05 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.2 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.4 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.6 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.8 [1] “T_Blind_spearman_LM_TRUE” T_Blind_spearman_LM_TRUE_0.95 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.05 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.2 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.4 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.6 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.8 [1] “T_Blind_spearman_RLM_FALSE” T_Blind_spearman_RLM_FALSE_0.95 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.05 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.2 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.4 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.6 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.8 [1] “T_Blind_spearman_RLM_TRUE” T_Blind_spearman_RLM_TRUE_0.95 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.05 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.2 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.4 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.6 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.8 [1] “T_Driven_fast_LM_FALSE” T_Driven_fast_LM_FALSE_0.95 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.05 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.2 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.4 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.6 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.8 [1] “T_Driven_fast_LM_TRUE” T_Driven_fast_LM_TRUE_0.95 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.05 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.2 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.4 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.6 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.8 [1] “T_Driven_fast_RLM_FALSE” T_Driven_fast_RLM_FALSE_0.95 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.05 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.2 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.4 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.6 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.8 [1] “T_Driven_fast_RLM_TRUE” T_Driven_fast_RLM_TRUE_0.95 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.05 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.2 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.4 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.6 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.8 [1] “T_Driven_pearson_LM_FALSE” T_Driven_pearson_LM_FALSE_0.95 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.05 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.2 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.4 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.6 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.8 [1] “T_Driven_pearson_LM_TRUE” T_Driven_pearson_LM_TRUE_0.95 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.05 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.2 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.4 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.6 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.8 [1] “T_Driven_pearson_RLM_FALSE” T_Driven_pearson_RLM_FALSE_0.95 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.05 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.2 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.4 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.6 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.8 [1] “T_Driven_pearson_RLM_TRUE” T_Driven_pearson_RLM_TRUE_0.95 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.05 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.2 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.4 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.6 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.8 [1] “T_Driven_spearman_LM_FALSE” T_Driven_spearman_LM_FALSE_0.95 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.05 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.2 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.4 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.6 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.8 [1] “T_Driven_spearman_LM_TRUE” T_Driven_spearman_LM_TRUE_0.95 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.05 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.2 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.4 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.6 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.8 [1] “T_Driven_spearman_RLM_FALSE” T_Driven_spearman_RLM_FALSE_0.95 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.05 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.2 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.4 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.6 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.8 [1] “T_Driven_spearman_RLM_TRUE” T_Driven_spearman_RLM_TRUE_0.95

par(op)

1.2.1 Printing the analysis outputs

par(op)
par(mfrow=c(1,2),cex=0.6)

rownames(totBaM) <- thenames
rownames(totDeM) <- thenames
rownames(toUnmatM) <- thenames
rownames(unalteredM) <- thenames
rownames(Decorrleated_FractionM) <- thenames
rownames(Base_FractionM) <- thenames
rownames(Unaltered_FractionM) <- thenames
rownames(sparcityM) <- thenames
rownames(Average_Latent_SizeM) <- thenames
rownames(SigDeM) <- thenames
rownames(La_SignificantM) <- thenames
rownames(pbKNNaucM) <- thenames
rownames(pbKNNaccM) <- thenames

colnames(totBaM) <- thr
colnames(totDeM) <- thr
colnames(toUnmatM) <- thr
colnames(unalteredM) <- thr
colnames(Decorrleated_FractionM) <- thr
colnames(Base_FractionM) <- thr
colnames(Unaltered_FractionM) <- thr
colnames(sparcityM) <- thr
colnames(Average_Latent_SizeM) <- thr
colnames(SigDeM) <- thr
colnames(La_SignificantM) <- thr
colnames(pbKNNaucM) <- thr
colnames(pbKNNaccM) <- thr

pander::pander(totFe)

753


pander::pander(totBaM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 1 3 36 55 74 114
T_Blind_fast_LM_TRUE 6 1 22 39 49 104
T_Blind_fast_RLM_FALSE 1 3 36 55 74 114
T_Blind_fast_RLM_TRUE 6 1 22 39 49 104
T_Blind_pearson_LM_FALSE 1 3 35 55 74 114
T_Blind_pearson_LM_TRUE 1 5 22 39 49 104
T_Blind_pearson_RLM_FALSE 29 20 41 55 69 114
T_Blind_pearson_RLM_TRUE 39 34 42 36 48 104
T_Blind_spearman_LM_FALSE 9 8 30 40 66 103
T_Blind_spearman_LM_TRUE 9 5 29 31 49 86
T_Blind_spearman_RLM_FALSE 17 13 24 40 65 99
T_Blind_spearman_RLM_TRUE 16 10 18 28 46 84
T_Driven_fast_LM_FALSE 19 20 34 57 71 116
T_Driven_fast_LM_TRUE 11 13 30 44 52 106
T_Driven_fast_RLM_FALSE 19 20 34 57 71 116
T_Driven_fast_RLM_TRUE 11 13 30 44 52 106
T_Driven_pearson_LM_FALSE 18 18 34 57 71 116
T_Driven_pearson_LM_TRUE 8 9 31 44 52 106
T_Driven_pearson_RLM_FALSE 30 35 52 64 71 118
T_Driven_pearson_RLM_TRUE 29 41 47 53 57 108
T_Driven_spearman_LM_FALSE 29 22 35 41 66 106
T_Driven_spearman_LM_TRUE 21 18 31 39 54 92
T_Driven_spearman_RLM_FALSE 26 28 36 45 65 102
T_Driven_spearman_RLM_TRUE 17 21 33 37 48 89
pander::pander(totDeM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 751 749 648 571 483 306
T_Blind_fast_LM_TRUE 737 751 665 590 507 315
T_Blind_fast_RLM_FALSE 751 749 648 571 483 306
T_Blind_fast_RLM_TRUE 737 751 665 590 507 315
T_Blind_pearson_LM_FALSE 751 749 648 571 483 306
T_Blind_pearson_LM_TRUE 751 712 665 590 507 315
T_Blind_pearson_RLM_FALSE 596 623 596 553 477 304
T_Blind_pearson_RLM_TRUE 574 589 573 564 498 310
T_Blind_spearman_LM_FALSE 638 625 596 564 483 336
T_Blind_spearman_LM_TRUE 628 650 593 574 500 356
T_Blind_spearman_RLM_FALSE 599 602 610 569 485 335
T_Blind_spearman_RLM_TRUE 614 615 618 581 500 355
T_Driven_fast_LM_FALSE 699 695 649 569 486 303
T_Driven_fast_LM_TRUE 684 692 658 585 506 313
T_Driven_fast_RLM_FALSE 699 695 649 569 486 303
T_Driven_fast_RLM_TRUE 684 692 658 585 506 313
T_Driven_pearson_LM_FALSE 695 705 649 569 486 303
T_Driven_pearson_LM_TRUE 697 711 655 585 506 313
T_Driven_pearson_RLM_FALSE 606 594 570 535 471 297
T_Driven_pearson_RLM_TRUE 601 579 569 546 486 303
T_Driven_spearman_LM_FALSE 586 602 590 565 486 333
T_Driven_spearman_LM_TRUE 600 613 601 575 495 352
T_Driven_spearman_RLM_FALSE 583 581 592 566 486 334
T_Driven_spearman_RLM_TRUE 606 609 595 571 498 351
pander::pander(toUnmatM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 1 3 36 55 74 114
T_Blind_fast_LM_TRUE 6 1 22 39 49 104
T_Blind_fast_RLM_FALSE 1 3 36 55 74 114
T_Blind_fast_RLM_TRUE 6 1 22 39 49 104
T_Blind_pearson_LM_FALSE 1 3 35 55 74 114
T_Blind_pearson_LM_TRUE 1 5 22 39 49 104
T_Blind_pearson_RLM_FALSE 29 20 41 55 69 114
T_Blind_pearson_RLM_TRUE 39 34 42 36 48 104
T_Blind_spearman_LM_FALSE 9 8 30 40 66 103
T_Blind_spearman_LM_TRUE 9 5 29 31 49 86
T_Blind_spearman_RLM_FALSE 17 13 24 40 65 99
T_Blind_spearman_RLM_TRUE 16 10 18 28 46 84
T_Driven_fast_LM_FALSE 19 20 34 57 71 116
T_Driven_fast_LM_TRUE 11 13 30 44 52 106
T_Driven_fast_RLM_FALSE 19 20 34 57 71 116
T_Driven_fast_RLM_TRUE 11 13 30 44 52 106
T_Driven_pearson_LM_FALSE 18 18 34 57 71 116
T_Driven_pearson_LM_TRUE 8 9 31 44 52 106
T_Driven_pearson_RLM_FALSE 30 35 52 64 71 118
T_Driven_pearson_RLM_TRUE 29 41 47 53 57 108
T_Driven_spearman_LM_FALSE 29 22 35 41 66 106
T_Driven_spearman_LM_TRUE 21 18 31 39 54 92
T_Driven_spearman_RLM_FALSE 26 28 36 45 65 102
T_Driven_spearman_RLM_TRUE 17 21 33 37 48 89
pander::pander(unalteredM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 2 4 105 182 270 447
T_Blind_fast_LM_TRUE 16 2 88 163 246 438
T_Blind_fast_RLM_FALSE 2 4 105 182 270 447
T_Blind_fast_RLM_TRUE 16 2 88 163 246 438
T_Blind_pearson_LM_FALSE 2 4 105 182 270 447
T_Blind_pearson_LM_TRUE 2 41 88 163 246 438
T_Blind_pearson_RLM_FALSE 157 130 157 200 276 449
T_Blind_pearson_RLM_TRUE 179 164 180 189 255 443
T_Blind_spearman_LM_FALSE 115 128 157 189 270 417
T_Blind_spearman_LM_TRUE 125 103 160 179 253 397
T_Blind_spearman_RLM_FALSE 154 151 143 184 268 418
T_Blind_spearman_RLM_TRUE 139 138 135 172 253 398
T_Driven_fast_LM_FALSE 54 58 104 184 267 450
T_Driven_fast_LM_TRUE 69 61 95 168 247 440
T_Driven_fast_RLM_FALSE 54 58 104 184 267 450
T_Driven_fast_RLM_TRUE 69 61 95 168 247 440
T_Driven_pearson_LM_FALSE 58 48 104 184 267 450
T_Driven_pearson_LM_TRUE 56 42 98 168 247 440
T_Driven_pearson_RLM_FALSE 147 159 183 218 282 456
T_Driven_pearson_RLM_TRUE 152 174 184 207 267 450
T_Driven_spearman_LM_FALSE 167 151 163 188 267 420
T_Driven_spearman_LM_TRUE 153 140 152 178 258 401
T_Driven_spearman_RLM_FALSE 170 172 161 187 267 419
T_Driven_spearman_RLM_TRUE 147 144 158 182 255 402
pander::pander(Decorrleated_FractionM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.997 0.995 0.861 0.758 0.641 0.406
T_Blind_fast_LM_TRUE 0.979 0.997 0.883 0.784 0.673 0.418
T_Blind_fast_RLM_FALSE 0.997 0.995 0.861 0.758 0.641 0.406
T_Blind_fast_RLM_TRUE 0.979 0.997 0.883 0.784 0.673 0.418
T_Blind_pearson_LM_FALSE 0.997 0.995 0.861 0.758 0.641 0.406
T_Blind_pearson_LM_TRUE 0.997 0.946 0.883 0.784 0.673 0.418
T_Blind_pearson_RLM_FALSE 0.792 0.827 0.792 0.734 0.633 0.404
T_Blind_pearson_RLM_TRUE 0.762 0.782 0.761 0.749 0.661 0.412
T_Blind_spearman_LM_FALSE 0.847 0.830 0.792 0.749 0.641 0.446
T_Blind_spearman_LM_TRUE 0.834 0.863 0.788 0.762 0.664 0.473
T_Blind_spearman_RLM_FALSE 0.795 0.799 0.810 0.756 0.644 0.445
T_Blind_spearman_RLM_TRUE 0.815 0.817 0.821 0.772 0.664 0.471
T_Driven_fast_LM_FALSE 0.928 0.923 0.862 0.756 0.645 0.402
T_Driven_fast_LM_TRUE 0.908 0.919 0.874 0.777 0.672 0.416
T_Driven_fast_RLM_FALSE 0.928 0.923 0.862 0.756 0.645 0.402
T_Driven_fast_RLM_TRUE 0.908 0.919 0.874 0.777 0.672 0.416
T_Driven_pearson_LM_FALSE 0.923 0.936 0.862 0.756 0.645 0.402
T_Driven_pearson_LM_TRUE 0.926 0.944 0.870 0.777 0.672 0.416
T_Driven_pearson_RLM_FALSE 0.805 0.789 0.757 0.710 0.625 0.394
T_Driven_pearson_RLM_TRUE 0.798 0.769 0.756 0.725 0.645 0.402
T_Driven_spearman_LM_FALSE 0.778 0.799 0.784 0.750 0.645 0.442
T_Driven_spearman_LM_TRUE 0.797 0.814 0.798 0.764 0.657 0.467
T_Driven_spearman_RLM_FALSE 0.774 0.772 0.786 0.752 0.645 0.444
T_Driven_spearman_RLM_TRUE 0.805 0.809 0.790 0.758 0.661 0.466
pander::pander(Base_FractionM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.00133 0.00398 0.0478 0.0730 0.0983 0.151
T_Blind_fast_LM_TRUE 0.00797 0.00133 0.0292 0.0518 0.0651 0.138
T_Blind_fast_RLM_FALSE 0.00133 0.00398 0.0478 0.0730 0.0983 0.151
T_Blind_fast_RLM_TRUE 0.00797 0.00133 0.0292 0.0518 0.0651 0.138
T_Blind_pearson_LM_FALSE 0.00133 0.00398 0.0465 0.0730 0.0983 0.151
T_Blind_pearson_LM_TRUE 0.00133 0.00664 0.0292 0.0518 0.0651 0.138
T_Blind_pearson_RLM_FALSE 0.03851 0.02656 0.0544 0.0730 0.0916 0.151
T_Blind_pearson_RLM_TRUE 0.05179 0.04515 0.0558 0.0478 0.0637 0.138
T_Blind_spearman_LM_FALSE 0.01195 0.01062 0.0398 0.0531 0.0876 0.137
T_Blind_spearman_LM_TRUE 0.01195 0.00664 0.0385 0.0412 0.0651 0.114
T_Blind_spearman_RLM_FALSE 0.02258 0.01726 0.0319 0.0531 0.0863 0.131
T_Blind_spearman_RLM_TRUE 0.02125 0.01328 0.0239 0.0372 0.0611 0.112
T_Driven_fast_LM_FALSE 0.02523 0.02656 0.0452 0.0757 0.0943 0.154
T_Driven_fast_LM_TRUE 0.01461 0.01726 0.0398 0.0584 0.0691 0.141
T_Driven_fast_RLM_FALSE 0.02523 0.02656 0.0452 0.0757 0.0943 0.154
T_Driven_fast_RLM_TRUE 0.01461 0.01726 0.0398 0.0584 0.0691 0.141
T_Driven_pearson_LM_FALSE 0.02390 0.02390 0.0452 0.0757 0.0943 0.154
T_Driven_pearson_LM_TRUE 0.01062 0.01195 0.0412 0.0584 0.0691 0.141
T_Driven_pearson_RLM_FALSE 0.03984 0.04648 0.0691 0.0850 0.0943 0.157
T_Driven_pearson_RLM_TRUE 0.03851 0.05445 0.0624 0.0704 0.0757 0.143
T_Driven_spearman_LM_FALSE 0.03851 0.02922 0.0465 0.0544 0.0876 0.141
T_Driven_spearman_LM_TRUE 0.02789 0.02390 0.0412 0.0518 0.0717 0.122
T_Driven_spearman_RLM_FALSE 0.03453 0.03718 0.0478 0.0598 0.0863 0.135
T_Driven_spearman_RLM_TRUE 0.02258 0.02789 0.0438 0.0491 0.0637 0.118
pander::pander(Unaltered_FractionM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.00266 0.00531 0.139 0.242 0.359 0.594
T_Blind_fast_LM_TRUE 0.02125 0.00266 0.117 0.216 0.327 0.582
T_Blind_fast_RLM_FALSE 0.00266 0.00531 0.139 0.242 0.359 0.594
T_Blind_fast_RLM_TRUE 0.02125 0.00266 0.117 0.216 0.327 0.582
T_Blind_pearson_LM_FALSE 0.00266 0.00531 0.139 0.242 0.359 0.594
T_Blind_pearson_LM_TRUE 0.00266 0.05445 0.117 0.216 0.327 0.582
T_Blind_pearson_RLM_FALSE 0.20850 0.17264 0.208 0.266 0.367 0.596
T_Blind_pearson_RLM_TRUE 0.23772 0.21780 0.239 0.251 0.339 0.588
T_Blind_spearman_LM_FALSE 0.15272 0.16999 0.208 0.251 0.359 0.554
T_Blind_spearman_LM_TRUE 0.16600 0.13679 0.212 0.238 0.336 0.527
T_Blind_spearman_RLM_FALSE 0.20452 0.20053 0.190 0.244 0.356 0.555
T_Blind_spearman_RLM_TRUE 0.18459 0.18327 0.179 0.228 0.336 0.529
T_Driven_fast_LM_FALSE 0.07171 0.07703 0.138 0.244 0.355 0.598
T_Driven_fast_LM_TRUE 0.09163 0.08101 0.126 0.223 0.328 0.584
T_Driven_fast_RLM_FALSE 0.07171 0.07703 0.138 0.244 0.355 0.598
T_Driven_fast_RLM_TRUE 0.09163 0.08101 0.126 0.223 0.328 0.584
T_Driven_pearson_LM_FALSE 0.07703 0.06375 0.138 0.244 0.355 0.598
T_Driven_pearson_LM_TRUE 0.07437 0.05578 0.130 0.223 0.328 0.584
T_Driven_pearson_RLM_FALSE 0.19522 0.21116 0.243 0.290 0.375 0.606
T_Driven_pearson_RLM_TRUE 0.20186 0.23108 0.244 0.275 0.355 0.598
T_Driven_spearman_LM_FALSE 0.22178 0.20053 0.216 0.250 0.355 0.558
T_Driven_spearman_LM_TRUE 0.20319 0.18592 0.202 0.236 0.343 0.533
T_Driven_spearman_RLM_FALSE 0.22576 0.22842 0.214 0.248 0.355 0.556
T_Driven_spearman_RLM_TRUE 0.19522 0.19124 0.210 0.242 0.339 0.534
pander::pander(sparcityM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.85486 0.83684 0.02432 0.00418 0.00254 0.00199
T_Blind_fast_LM_TRUE 0.14325 0.95355 0.03543 0.00480 0.00279 0.00206
T_Blind_fast_RLM_FALSE 0.85486 0.83684 0.02432 0.00418 0.00254 0.00199
T_Blind_fast_RLM_TRUE 0.14325 0.95355 0.03543 0.00480 0.00279 0.00206
T_Blind_pearson_LM_FALSE 0.85022 0.86646 0.02609 0.00418 0.00254 0.00199
T_Blind_pearson_LM_TRUE 0.72133 0.05020 0.03543 0.00480 0.00279 0.00206
T_Blind_pearson_RLM_FALSE 0.00395 0.00452 0.00387 0.00331 0.00272 0.00213
T_Blind_pearson_RLM_TRUE 0.00357 0.00425 0.00507 0.00352 0.00317 0.00214
T_Blind_spearman_LM_FALSE 0.00640 0.00609 0.00505 0.00377 0.00272 0.00209
T_Blind_spearman_LM_TRUE 0.00563 0.01403 0.00540 0.00458 0.00291 0.00220
T_Blind_spearman_RLM_FALSE 0.00435 0.00469 0.00590 0.00365 0.00257 0.00204
T_Blind_spearman_RLM_TRUE 0.00429 0.00508 0.00747 0.00396 0.00268 0.00214
T_Driven_fast_LM_FALSE 0.03861 0.03560 0.02301 0.00428 0.00256 0.00198
T_Driven_fast_LM_TRUE 0.01492 0.02229 0.03427 0.00481 0.00277 0.00204
T_Driven_fast_RLM_FALSE 0.03861 0.03560 0.02301 0.00428 0.00256 0.00198
T_Driven_fast_RLM_TRUE 0.01492 0.02229 0.03427 0.00481 0.00277 0.00204
T_Driven_pearson_LM_FALSE 0.03346 0.04483 0.02314 0.00428 0.00256 0.00198
T_Driven_pearson_LM_TRUE 0.01596 0.03711 0.03055 0.00481 0.00277 0.00204
T_Driven_pearson_RLM_FALSE 0.00404 0.00390 0.00349 0.00305 0.00262 0.00204
T_Driven_pearson_RLM_TRUE 0.00366 0.00349 0.00335 0.00318 0.00282 0.00206
T_Driven_spearman_LM_FALSE 0.00465 0.00505 0.00540 0.00396 0.00281 0.00211
T_Driven_spearman_LM_TRUE 0.00468 0.00541 0.00544 0.00472 0.00290 0.00216
T_Driven_spearman_RLM_FALSE 0.00417 0.00410 0.00516 0.00387 0.00255 0.00205
T_Driven_spearman_RLM_TRUE 0.00461 0.00533 0.00526 0.00370 0.00269 0.00211
pander::pander(Average_Latent_SizeM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 664.00 627.00 2.50 2.00 2.29 2.00
T_Blind_fast_LM_TRUE 8.00 726.00 8.00 2.00 2.08 2.00
T_Blind_fast_RLM_FALSE 664.00 627.00 2.50 2.00 2.29 2.00
T_Blind_fast_RLM_TRUE 8.00 726.00 8.00 2.00 2.08 2.00
T_Blind_pearson_LM_FALSE 602.50 650.00 3.67 2.00 2.29 2.00
T_Blind_pearson_LM_TRUE 582.00 37.17 8.00 2.00 2.08 2.00
T_Blind_pearson_RLM_FALSE 2.67 3.00 3.60 2.90 2.33 2.11
T_Blind_pearson_RLM_TRUE 2.20 2.17 4.19 2.20 3.09 2.27
T_Blind_spearman_LM_FALSE 4.00 2.50 5.00 3.00 2.23 2.00
T_Blind_spearman_LM_TRUE 2.00 3.33 2.40 3.15 2.00 2.12
T_Blind_spearman_RLM_FALSE 3.40 3.00 8.00 2.25 2.10 2.00
T_Blind_spearman_RLM_TRUE 3.43 2.00 6.80 3.42 2.17 2.08
T_Driven_fast_LM_FALSE 6.00 NA 12.86 3.00 2.12 2.00
T_Driven_fast_LM_TRUE NA 18.00 NA 2.75 2.36 2.44
T_Driven_fast_RLM_FALSE 6.00 NA 12.86 3.00 2.12 2.00
T_Driven_fast_RLM_TRUE NA 18.00 NA 2.75 2.36 2.44
T_Driven_pearson_LM_FALSE NA NA 12.86 3.00 2.12 2.00
T_Driven_pearson_LM_TRUE 10.00 15.00 5.00 2.75 2.36 2.44
T_Driven_pearson_RLM_FALSE 3.00 3.00 2.33 2.00 2.10 2.12
T_Driven_pearson_RLM_TRUE 2.00 NA 3.00 2.00 2.25 2.58
T_Driven_spearman_LM_FALSE 2.00 5.00 2.00 2.00 2.43 2.25
T_Driven_spearman_LM_TRUE NA 2.00 2.80 2.83 2.00 2.14
T_Driven_spearman_RLM_FALSE NA 3.17 3.00 2.33 2.18 2.20
T_Driven_spearman_RLM_TRUE NA NA 3.00 3.50 2.62 2.18
pander::pander(SigDeM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 1 1 2 4 7 6
T_Blind_fast_LM_TRUE 1 2 1 2 12 7
T_Blind_fast_RLM_FALSE 1 1 2 4 7 6
T_Blind_fast_RLM_TRUE 1 2 1 2 12 7
T_Blind_pearson_LM_FALSE 2 1 3 4 7 6
T_Blind_pearson_LM_TRUE 1 6 1 2 12 7
T_Blind_pearson_RLM_FALSE 9 8 10 10 15 9
T_Blind_pearson_RLM_TRUE 5 6 16 5 11 11
T_Blind_spearman_LM_FALSE 9 2 3 4 13 3
T_Blind_spearman_LM_TRUE 2 3 5 13 7 8
T_Blind_spearman_RLM_FALSE 5 1 2 4 10 7
T_Blind_spearman_RLM_TRUE 7 1 5 12 6 13
T_Driven_fast_LM_FALSE 1 0 7 8 8 5
T_Driven_fast_LM_TRUE 0 3 0 8 11 9
T_Driven_fast_RLM_FALSE 1 0 7 8 8 5
T_Driven_fast_RLM_TRUE 0 3 0 8 11 9
T_Driven_pearson_LM_FALSE 0 0 7 8 8 5
T_Driven_pearson_LM_TRUE 1 1 1 8 11 9
T_Driven_pearson_RLM_FALSE 3 9 3 2 10 8
T_Driven_pearson_RLM_TRUE 1 0 3 2 8 12
T_Driven_spearman_LM_FALSE 2 1 1 2 7 4
T_Driven_spearman_LM_TRUE 0 3 5 6 9 7
T_Driven_spearman_RLM_FALSE 0 6 4 9 11 10
T_Driven_spearman_RLM_TRUE 0 0 2 6 8 17
pander::pander(La_SignificantM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 1 1 2 6 24 65
T_Blind_fast_LM_TRUE 1 2 1 2 31 64
T_Blind_fast_RLM_FALSE 1 1 2 6 24 65
T_Blind_fast_RLM_TRUE 1 2 1 2 31 64
T_Blind_pearson_LM_FALSE 2 1 3 6 24 65
T_Blind_pearson_LM_TRUE 1 7 1 2 31 64
T_Blind_pearson_RLM_FALSE 10 9 13 17 40 70
T_Blind_pearson_RLM_TRUE 10 10 22 13 29 70
T_Blind_spearman_LM_FALSE 9 2 4 10 36 50
T_Blind_spearman_LM_TRUE 3 4 7 21 24 54
T_Blind_spearman_RLM_FALSE 6 1 2 10 29 56
T_Blind_spearman_RLM_TRUE 8 3 6 17 20 61
T_Driven_fast_LM_FALSE 2 2 9 17 29 65
T_Driven_fast_LM_TRUE 1 4 1 17 33 72
T_Driven_fast_RLM_FALSE 2 2 9 17 29 65
T_Driven_fast_RLM_TRUE 1 4 1 17 33 72
T_Driven_pearson_LM_FALSE 1 2 9 17 29 65
T_Driven_pearson_LM_TRUE 2 2 2 17 33 72
T_Driven_pearson_RLM_FALSE 5 14 8 9 36 70
T_Driven_pearson_RLM_TRUE 2 3 8 9 29 75
T_Driven_spearman_LM_FALSE 3 2 3 8 24 54
T_Driven_spearman_LM_TRUE 1 4 7 14 31 56
T_Driven_spearman_RLM_FALSE 1 8 6 16 33 62
T_Driven_spearman_RLM_TRUE 1 1 4 14 25 69
pander::pander(pbKNNaucM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.408 0.607 0.652 0.758 0.841 0.827
T_Blind_fast_LM_TRUE 0.617 0.503 0.595 0.694 0.838 0.802
T_Blind_fast_RLM_FALSE 0.408 0.607 0.652 0.758 0.841 0.827
T_Blind_fast_RLM_TRUE 0.617 0.503 0.595 0.694 0.838 0.802
T_Blind_pearson_LM_FALSE 0.498 0.504 0.695 0.758 0.841 0.827
T_Blind_pearson_LM_TRUE 0.600 0.720 0.595 0.694 0.838 0.802
T_Blind_pearson_RLM_FALSE 0.727 0.733 0.739 0.780 0.775 0.798
T_Blind_pearson_RLM_TRUE 0.772 0.847 0.785 0.843 0.824 0.782
T_Blind_spearman_LM_FALSE 0.803 0.753 0.785 0.795 0.833 0.814
T_Blind_spearman_LM_TRUE 0.746 0.776 0.775 0.797 0.825 0.831
T_Blind_spearman_RLM_FALSE 0.738 0.504 0.623 0.794 0.805 0.737
T_Blind_spearman_RLM_TRUE 0.671 0.739 0.741 0.770 0.784 0.785
T_Driven_fast_LM_FALSE 0.732 0.740 0.780 0.852 0.836 0.798
T_Driven_fast_LM_TRUE 0.607 0.683 0.721 0.819 0.868 0.797
T_Driven_fast_RLM_FALSE 0.732 0.740 0.780 0.852 0.836 0.798
T_Driven_fast_RLM_TRUE 0.607 0.683 0.721 0.819 0.868 0.797
T_Driven_pearson_LM_FALSE 0.607 0.740 0.780 0.852 0.836 0.798
T_Driven_pearson_LM_TRUE 0.657 0.701 0.720 0.819 0.868 0.797
T_Driven_pearson_RLM_FALSE 0.763 0.717 0.697 0.777 0.754 0.795
T_Driven_pearson_RLM_TRUE 0.763 0.818 0.745 0.818 0.825 0.787
T_Driven_spearman_LM_FALSE 0.759 0.797 0.783 0.838 0.843 0.797
T_Driven_spearman_LM_TRUE 0.607 0.795 0.696 0.789 0.835 0.844
T_Driven_spearman_RLM_FALSE 0.607 0.770 0.636 0.787 0.747 0.706
T_Driven_spearman_RLM_TRUE 0.607 0.799 0.665 0.817 0.809 0.719
pander::pander(pbKNNaccM)
  0.05 0.2 0.4 0.6 0.8 0.95
T_Blind_fast_LM_FALSE 0.651 0.738 0.746 0.817 0.873 0.825
T_Blind_fast_LM_TRUE 0.69 0.579 0.698 0.714 0.873 0.833
T_Blind_fast_RLM_FALSE 0.651 0.738 0.746 0.817 0.873 0.825
T_Blind_fast_RLM_TRUE 0.69 0.579 0.698 0.714 0.873 0.833
T_Blind_pearson_LM_FALSE 0.706 0.714 0.698 0.817 0.873 0.825
T_Blind_pearson_LM_TRUE 0.69 0.746 0.698 0.714 0.873 0.833
T_Blind_pearson_RLM_FALSE 0.81 0.81 0.802 0.81 0.833 0.794
T_Blind_pearson_RLM_TRUE 0.825 0.825 0.817 0.873 0.881 0.817
T_Blind_spearman_LM_FALSE 0.794 0.73 0.825 0.857 0.865 0.833
T_Blind_spearman_LM_TRUE 0.754 0.81 0.794 0.849 0.849 0.833
T_Blind_spearman_RLM_FALSE 0.802 0.635 0.714 0.833 0.817 0.817
T_Blind_spearman_RLM_TRUE 0.754 0.762 0.77 0.802 0.786 0.833
T_Driven_fast_LM_FALSE 0.746 0.794 0.794 0.865 0.873 0.817
T_Driven_fast_LM_TRUE 0.706 0.698 0.738 0.802 0.849 0.841
T_Driven_fast_RLM_FALSE 0.746 0.794 0.794 0.865 0.873 0.817
T_Driven_fast_RLM_TRUE 0.706 0.698 0.738 0.802 0.849 0.841
T_Driven_pearson_LM_FALSE 0.706 0.794 0.794 0.865 0.873 0.817
T_Driven_pearson_LM_TRUE 0.706 0.786 0.833 0.802 0.849 0.841
T_Driven_pearson_RLM_FALSE 0.802 0.817 0.802 0.817 0.77 0.817
T_Driven_pearson_RLM_TRUE 0.802 0.802 0.778 0.802 0.865 0.825
T_Driven_spearman_LM_FALSE 0.754 0.778 0.802 0.817 0.841 0.825
T_Driven_spearman_LM_TRUE 0.706 0.81 0.778 0.825 0.849 0.817
T_Driven_spearman_RLM_FALSE 0.706 0.786 0.746 0.825 0.802 0.802
T_Driven_spearman_RLM_TRUE 0.706 0.833 0.778 0.865 0.841 0.81

miny = 0.15
maxy = max(pbKNNaucM)

plot(thr,pbKNNaucM[1,],ylim=c(miny,maxy),
     main="KNN's ROCAUC",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="ROC AUC",
     type="l",
     col=1,
     lwd=2)
for (ind in 2:nrow(pbKNNaucM))
{
  lines(thr,pbKNNaucM[ind,],col=ind,lwd=2,lty=ind)
}

legend("bottomright", rownames(pbKNNaucM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)

fastRows <- str_detect(rownames(pbKNNaucM),"fast")
pearsonRows <- str_detect(rownames(pbKNNaucM),"pearson")
spearmanRows <- str_detect(rownames(pbKNNaucM),"spearman")
T_BlindRows <- str_detect(rownames(pbKNNaucM),"T_Blind")
corRankRows <- str_detect(rownames(pbKNNaucM),"TRUE")
maxCorRankRows <- str_detect(rownames(pbKNNaucM),"FALSE")
RLMfitMethod <- str_detect(rownames(pbKNNaucM),"RLM")


meanAuc <-  colMeans(pbKNNaucM[fastRows,])
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[pearsonRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[spearmanRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[!T_BlindRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[T_BlindRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[corRankRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[maxCorRankRows,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[RLMfitMethod,]))
meanAuc <-  rbind(meanAuc,colMeans(pbKNNaucM[!RLMfitMethod,]))
legnames <- c("fast","Pearson","Spearman","T_Driven","T_Blind","SumCor","MaxCor","RLM","LM")


pbKNNaccM <- as.data.frame(pbKNNaccM)
pbKNNaccM[,1:ncol(pbKNNaccM)] <- sapply(pbKNNaccM,as.numeric)

Average_Latent_SizeM <- as.data.frame(Average_Latent_SizeM)
Average_Latent_SizeM[,1:ncol(Average_Latent_SizeM)] <- sapply(Average_Latent_SizeM,as.numeric)
Average_Latent_SizeM[is.na(Average_Latent_SizeM)] <- 0

SigDeM <- as.data.frame(SigDeM)
SigDeM[,1:ncol(SigDeM)] <- sapply(SigDeM,as.numeric)

sparcityM <- as.data.frame(sparcityM)
sparcityM[,1:ncol(sparcityM)] <- sapply(sparcityM,as.numeric)

miny = 0.65
maxy = max(meanAuc)+0.025

plot(thr,meanAuc[1,],ylim=c(miny,maxy),
     main="Mean KNN's ROCAUC",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="ROC AUC",
     type="l",
     col=1,
     lwd=2,
     lty=1)
for (ind in 2:nrow(meanAuc))
{
  lines(thr,meanAuc[ind,],col=ind,lwd=2,lty=ind)
}
legend("bottomright", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)



miny = 0.35
maxy = max(pbKNNaccM) + 0.1

plot(thr,pbKNNaccM[1,],ylim=c(miny,maxy),
     main="KNN's Accuracy",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Accuracy",
     type="l",
     col=1,
     lwd=2)
for (ind in 2:nrow(pbKNNaucM))
{
  lines(thr,pbKNNaccM[ind,],col=ind,lwd=2,lty=ind)
}
legend("bottomright", rownames(pbKNNaucM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)



meanAcc <-  colMeans(pbKNNaccM[fastRows,])
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[pearsonRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[spearmanRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[!T_BlindRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[T_BlindRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[corRankRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[maxCorRankRows,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[RLMfitMethod,]))
meanAcc <-  rbind(meanAcc,colMeans(pbKNNaccM[!RLMfitMethod,]))

miny = min(meanAcc)-0.01
maxy = max(meanAcc)+0.025

plot(thr,meanAcc[1,],ylim=c(miny,maxy),
     main="Mean KNN's Accuracy",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Accuracy",
     type="l",
     col=1,
     lwd=2)
for (ind in 2:nrow(meanAcc))
{
  lines(thr,meanAcc[ind,],col=ind,lwd=2,lty=ind)
}
legend("topleft", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)





miny = 1
maxy = 20*max(Average_Latent_SizeM)

plot(thr,Average_Latent_SizeM[1,],ylim=c(miny,maxy),
     main="Average Size of Latent-Variable",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Size",
     type="l",
     col=1,
     lwd=2,
     log = "y")

for (ind in 2:nrow(Average_Latent_SizeM))
{
  lines(thr,Average_Latent_SizeM[ind,],col=ind,lwd=2,lty=ind)
}
legend("topright", rownames(Average_Latent_SizeM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)




meanAccAvgSize <-  colMeans(Average_Latent_SizeM[fastRows,])
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[pearsonRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[spearmanRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[!T_BlindRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[T_BlindRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[corRankRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[maxCorRankRows,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[RLMfitMethod,]))
meanAccAvgSize <-  rbind(meanAccAvgSize,colMeans(Average_Latent_SizeM[!RLMfitMethod,]))

miny =1
maxy = 5*max(meanAccAvgSize)

plot(thr,meanAccAvgSize[1,],ylim=c(miny,maxy),
     main="Mean Size of Average-Latent-Variable",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Size",
     type="l",
     col=1,
     lwd=2,
     log = "y")
for (ind in 2:nrow(meanAccAvgSize))
{
  lines(thr,meanAccAvgSize[ind,],col=ind,lwd=2,lty=ind)
}
legend("topright", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)




miny = min(La_SignificantM)
maxy = 20*max(La_SignificantM)

plot(thr,La_SignificantM[1,],ylim=c(miny,maxy),
     main="Number of Discovered Features",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Number of Features",
     type="l",
     col=1,
     lwd=2,
     log = "y")

for (ind in 2:nrow(La_SignificantM))
{
  lines(thr,La_SignificantM[ind,],col=ind,lwd=2,lty=ind)
}
legend("topleft", rownames(La_SignificantM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)




meanDiscovered <-  colMeans(La_SignificantM[fastRows,])
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[pearsonRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[spearmanRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[!T_BlindRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[T_BlindRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[corRankRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[maxCorRankRows,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[RLMfitMethod,]))
meanDiscovered <-  rbind(meanDiscovered,colMeans(La_SignificantM[!RLMfitMethod,]))

miny = min(meanDiscovered)
maxy = max(meanDiscovered) + 10

plot(thr,meanDiscovered[1,],ylim=c(miny,maxy),
     main="Average Number of Discovered Features",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Number of Features",
     type="l",
     col=1,
     lwd=2,
     log = "y")
for (ind in 2:nrow(meanDiscovered))
{
  lines(thr,meanDiscovered[ind,],col=ind,lwd=2,lty=ind)
}
legend("bottomright", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)



SigDeM[is.na(SigDeM)] <- 0
miny = 1
maxy = 20*max(SigDeM)

plot(thr,SigDeM[1,],ylim=c(miny,maxy),
     main="Number of Significant Latent Variables",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="How Many",
     type="l",
     col=1,
     lwd=2,
     log = "y")

for (ind in 2:nrow(SigDeM))
{
  lines(thr,SigDeM[ind,],col=ind,lwd=2,lty=ind)
}
legend("topright", rownames(SigDeM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)



SigLatent <-  colMeans(SigDeM[fastRows,])
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[pearsonRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[spearmanRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[!T_BlindRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[T_BlindRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[corRankRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[maxCorRankRows,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[RLMfitMethod,]))
SigLatent <-  rbind(SigLatent,colMeans(SigDeM[!RLMfitMethod,]))

miny = 1
maxy = max(SigLatent) + 10


plot(thr,SigLatent[1,],ylim=c(miny,maxy),
     main="Average # of Significant Latent Variables",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="How Many",
     type="l",
     col=1,
     lwd=2,
     log = "y")
for (ind in 2:nrow(SigLatent))
{
  lines(thr,SigLatent[ind,],col=ind,lwd=2,lty=ind)
}
legend("bottomright", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)




sparcityM[is.na(sparcityM)] <- 0
miny = min(sparcityM)
maxy = max(sparcityM) + 0.75 

plot(thr,sparcityM[1,],ylim=c(miny,maxy),
     main="Matrix Sparcity",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Sparcity",
     type="l",
     col=1,
     lwd=2,
     log = "y")

for (ind in 2:nrow(sparcityM))
{
  lines(thr,sparcityM[ind,],col=ind,lwd=2,lty=ind)
}
legend("topright", rownames(sparcityM),lty=1:length(thenames), col = 1:length(thenames),cex=0.55,ncol=2)




meanSparcity <-  colMeans(sparcityM[fastRows,])
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[pearsonRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[spearmanRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[!T_BlindRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[T_BlindRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[corRankRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[maxCorRankRows,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[RLMfitMethod,]))
meanSparcity <-  rbind(meanSparcity,colMeans(sparcityM[!RLMfitMethod,]))

miny = min(meanSparcity)
maxy = max(meanSparcity)+0.25


plot(thr,meanSparcity[1,],ylim=c(miny,maxy),
     main="Mean Matrix Sparcity",
     xlab="Correlation-Matrix's Maximum Goal",
     ylab="Sparcity",
     type="l",
     col=1,
     lwd=2,
     log = "y")
for (ind in 2:nrow(meanSparcity))
{
  lines(thr,meanSparcity[ind,],col=ind,lwd=2,lty=ind)
}
legend("topright", legnames,lty=1:length(legnames), col = 1:length(legnames),cex=0.75)

1.2.2 Saving All


save.image("~/GitHub/LatentBiomarkers/RMD/Parkinsons_ALL_Options.RData")